home *** CD-ROM | disk | FTP | other *** search
Text File | 1992-09-08 | 7.7 KB | 185 lines | [TEXT/CCL2] |
- Extended Apropos: A Symbol Search Laboratory
-
- This set of files implements an extended Apropos dialog. It is a
- superset of MCL's standard Apropos dialog. You can use it to search
- for all of lisp symbols that match certain criteria.
-
- Copyright
-
- Extended Apropos: A Symbol Search Laboratory
- Copyright 1992 by Guillaume Cartier
-
- Permission to use, copy, modify, and distribute this software and its
- documentation for any purpose and without fee is hereby granted, provided
- that this copyright and permission notice appear in all copies and supporting
- documentation. There is no representations about the suitability of this
- software for any purpose. It is provided "as is" without express or implied
- warranty.
-
- Obtaining the Software
-
- This software can be obtained by anonymous ftp at cambridge.apple.com
- under directory pub/mcl2/contrib. If you do not have ftp access, you
- can contact:
- Guillaume Cartier
- Email: cartier@math.uqam.ca
-
- Change Log
-
- 17/03/92 First Release.
- 08/04/92 Corrected a bug reported by Michael Wirth which could
- cause problems when you saved an application.
- 22/04/92 Made two cosmetic improvements suggested by Kemi Jona.
- 22/04/92 Added a global variable *DEFAULT-PACKAGE* (to be found
- in the "apropos.lisp" file) that determines what package
- will be selected by default when the extended apropos
- is first brought up. This can be usefull, as I found I
- was selecting the "CL-USER" package 99% of the time!
- The extended apropos will now also remember what package
- is selected when you close its window.
- 06/05/92 Moving through the found symbols using the arrow keys
- did not update the state of the action buttons (reported
- by Matthew Cornell).
-
- To Do
-
- Notes
-
- The original idea for an extended apropos dialog came from
- Cristopher Fry's smart apropos dialog written in MCL 1.1.
-
- For MCL2.0b1p3 Users
-
- Here are the steps needed to convert extended apropos to MCL 2.0b1p3:
- (should take less than 5 minutes)
-
- - In the "LOADME" file, comment the 2 REQUIRE.
- (you won't get the nice ballow help, but I suppose you can live with that) :-)
-
- - In the "LOADME" file, comment the following line:
- "%BUFFER-SET-READ-ONLY"
-
- - In the "apropos.lisp" file, comment the following line:
- (make-instance 'search-thermometer :view-position #@(482 181))
-
- - In the "subviews.lisp" file, comment the following line: (at the top)
- (%buffer-set-read-only buffer t)
-
- - In the "subviews.lisp" file, replace the APROPOS-FILTER function
- with the following one: (you may want to do a search on this one...)
- (defun apropos-filter (symbols filter)
- (prog1 (filter symbols filter)
- (unless (and *foreground*
- (eq *apropos* (front-window)))
- (ed-beep))))
-
- That's it.
- Have fun.
-
- NB: I haven't tested all of extended apropos's features in MCL 2.0b1p3,
- but the most important ones should work fine.
-
- NB: If you experiment any problems using this procedure,
- let me know, I will see what can be done.
-
- Documentation
-
- Using the extended apropos should be strait forward. Balloon help is
- supported and can provide documentation for specific parts of the dialog.
- Try out balloon help on the list of found symbols for a nice feature.
-
- The only hidden feature of the extended apropos is the fact that the
- window can be resized even though it hasn't got a grow icon. That was
- a small concession I had to make to save screen space and make the
- dialog fit on small macintosh screens.
-
- There are three accelerators available in the found symbols table,
- corresponding to the three buttons on the right side:
-
- - double-clicking, control-clicking or command-clicking will inspect
- the selected symbol.
- - option-clicking will show documentation for the selected symbol.
- - option-control-clicking or option-command-clicking will edit the
- definition of the selected symbol.
-
- The extended apropos defines a copy method that copies the selected
- symbol's name to the clipboard (meaning you can use the Copy menu item
- on the extended apropos to save some typing).
-
- Tutorial
-
- This section provides step by step examples on how to use some of
- the features provided by the extended apropos.
-
- Scenario 1:
-
- - I want to find every function that relates to events and windows.
- - I type "event" in the text box and then click "Search".
- - Hum... that's to much symbols, I really don't care about all the
- internal ones, I would like to see only the external ones...
- - I select "Show only external symbols" and then click "Refine".
- - That's better.
- - Then I want only the symbols that relate to windows, so I type
- "window" and click "Refine".
- - Now I want only the symbols that represent functions so I select
- "name represents a function type: any" and click "Refine" (not
- forgeting to check the check box).
-
- Note: When you only want to see the 'official' symbols, i.e. the external
- ones, a trick that will do it nicely and very fastly is to select the
- "common-lisp-user" package and "Show only inherited symbols". This will
- give you all the external symbols of both the "common-lisp" and the
- "ccl" packages.
-
- Scenario 2:
-
- - I want to really delve into views, including all the internal stuff.
- - I type "view"
- - I select "Search into all packages" and "Show all symbols".
- - I click "Search" (it takes some time).
- - As I know this will be my base for future exploration, I anchor the
- found symbols as the base for future searches by clicking "Anchor".
- - I would like to know all of the found symbols which are functions, so I
- select "name represents a function type: any" and click "Search" (note
- that this search will be done only on the previously anchored symbols).
- - Hum... I wonder if any of those symbols are documented, so I select
- "documentation is available" and click "Refine".
- - Having done some exploration on functions, I now want to find which of
- those symbols are proclaimed special.
- - I select "name represents a value type: any" and click "Search".
- - Now I would like to have an idea of what their symbol values are, so
- I select "Show value" and check the check box in front of it.
-
- Scenario 3: (here is one for the developers) :-)
-
- - I wonder which symbols are still missing documentation and so will
- have to be documented for the final release.
- - Type in "" (search for ALL symbols).
- - Select the "common-lisp-user" package and "Show only inherited symbols".
- - Select "documentation is not available".
- - If necessary, click "Global" to restore the search domain to all symbols.
- - Click "Search".
- - Here are all the symbols that still have to be documented...
-
- Scenario 4: (remember all those discussions on warnings!)
-
- - I wonder what are all the warnings that MCL knows of.
- - Type in "".
- - Select package "ccl" and "Show all symbols".
- - Select "name represents a condition: warning".
- - Click "Search".
-
- Note: Some searches such as the one above can be lengthy. This is no
- problem! The searches can be done in background! Start the search
- and then continue whatever you where doing. When the search is
- finished, you will told so by a beep (the apropos will beep only if
- its window is not frontmost or if MCL is not the current application).
-
- References
-
- - Common Lisp the Language, Second Edition,
- Guy L. Steele Jr., Digital Press 1990
-
- - Macintosh Common Lisp 2.0 Reference (Draft)
- Apple Computer, Inc. 1991
-